﻿var admin = {
    //添加表单提交
    AddSubmit: function (backurl) {
        if ($("#form_ff_validation").valid()) {
            var url = $("#form_ff_validation").attr("action");
            $.ajax({
                url: url,
                data: $("#form_ff_validation").serialize(),
                type: "POST",
                success: function (result) {
                    if (result.resultCode == 1000) {
                        layer.msg(result.message, {
                            icon: 1,
                            time: 1500
                        }, function () {
                            location.href = backurl;
                        });
                    } else {
                        layer.open({
                            content: result.message
                        });
                    }
                }
            });
        }
    }
};